export default function getAsyncComponent(path) {
  if (path.indexOf('@/views/') === 0) {
    return () => Promise.resolve(require(`@/views/${path.replace('@/views/', '')}`).default)
  }
  if (path.indexOf('@/components/') === 0) {
    return () => Promise.resolve(require(`@/components/${path.replace('@/components/', '')}`).default)
  }
}
